package com.hpjpw.ido.config;

import com.qiniu.util.Auth;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @BelongsProject: RuoYi-IDo
 * @BelongsPackage: com.hpjpw.ido.config
 * @Author: hpj
 * @CreateTime: 2021-03-18 20:32
 * @Description: 七牛云存储
 */
@Configuration
class QiNiuConfiguration {
    @Autowired
    IDoConfig iDoConfig;
    @Bean
    public Auth qiNiuAuth(){
        String accessKey = iDoConfig.getAccessKey();
        String secretKey = iDoConfig.getSecretKey();

        return Auth.create(accessKey, secretKey);
    }
}
